The present invention relates to an electronic device, such as a video camera or the like, which is preferably utilized in a system controlling the electronic device from a personal computer through a network, and a computer-readable storage medium used in the electronic device.
Conventionally, peripherals of a personal computer (hereinafter referred to as a PC) such as hard disk or a printer or the like are connected to the PC for data communication through a general-purpose interface, such as the Small Computer System Interface (SCSI), typical of digital interfaces (hereinafter referred to as a digital I/F).
A digital camera and digital video camera are also peripherals for inputting data to a PC. Recently, more users use digital cameras and digital video cameras as the technology advances in the field of inputting to a PC, still image data or moving image data sensed by a digital camera or video camera along with audio data, then storing the data in hard disk of the PC or editing the data by the PC and outputting the data to be printed in color by a printer.
When image data is outputted from the PC to a printer or hard disk, data communication via SCSI is performed. In order to transmit a large amount of data such as image data, a digital I/F of general versatility, having a high data transfer rate is necessary.
FIG. 8 is a block diagram showing a conventional system in which a digital camera and a printer are connected to a PC.
Referring to FIG. 8, reference numeral 31 denotes a digital camera; 32, a personal computer (PC); and 33, a printer.
In the digital camera 31, reference numeral 34 denotes memory serving as a recording unit of the digital camera; 35, an image data decoder; 36, an image processor; 37, a D/A converter; 38, an electric view finder (EVF) serving as a display unit; and 39, a digital I/O unit of the digital camera.
In the PC 32, reference numeral 40 denotes a digital I/O unit for connecting the PC 32 to the digital camera 31; 41, an operation unit such as a keyboard, mouse or the like; 42, an image data decoder; 43, a display; 44, hard disk; 45, memory such as RAM or the like; 46, an MPU serving as a computation processor; 47, a PCI bus; 48, a SCSI interface (board) of the digital I/F.
In the printer 33, reference numeral 149 denotes a printer SCSI interface for connecting the printer 33 to the PC 32 through a SCSI cable; 150, memory; 151, a printer head; 152, a printer controller; and 153, a driver.
Next, description will be provided on the steps of inputting an image sensed by the digital camera 31 to the PC 32, and outputting the image data from the PC 32 to the printer 33.
When image data stored in the memory 34 of the digital camera 31 is read out, the read image data is, on one hand, decoded by the decoder 35, then subjected to image processing by the image processor 36 for displaying, and then processed by the D/A converter 37 to be displayed by the EVF 38. On the other hand, the read image data is outputted by the digital I/O unit 39 to the digital I/O unit 40 of the PC 32 through a cable.
In the PC 32, image data is inputted to the digital I/O unit 40 through the PCI bus 47 which serves as a two-way communication bus. When the image data is to be stored, the image data is stored in the hard disk 44, but when an image is to be displayed, the image data is decoded by the decoder 42, stored as display image data in the memory 45, and converted to analog signals in the display 43 to be displayed.
In the PC 32, an operation command such as an image edit command or the like is inputted by the operation unit 41. Processing for the entire PC 32 is executed by the MPU 46. For printing out an image, image data is transmitted from the SCSI interface board 48 of the PC 32 to the printer 33 through the SCSI cable. In the printer 33, the transmitted image data is received by the SCSI interface 149, and stored as print image data in the memory 150. Then, the printer controller 152 controls the printer head 151 and driver 153 according to the print image data read out of the memory 150 and an image is printed.
The foregoing are conventional steps of inputting image data to a PC and printing an image. As is apparent from the above description, conventionally, respective devices are connected to a PC serving as a host computer, and image data sensed by a digital camera is printed via the PC.
However, the aforementioned SCSI includes a type with a low data transfer rate, or one having a thick cable for parallel communication, or one with a limited type and method of connecting peripherals. Besides these, various other inconvenient aspects have been pointed out, e.g., the SCSI requires as many I/F connectors as the number of connected devices. Furthermore, many general home-use PCs or digital devices have connectors on the back of the PC for connecting the SCSI or other cables. Moreover, the large shape of the connector makes plugging in/out of the cable cumbersome.
Even in a case of connecting a mobile or portable device which normally is not used as a desk-top type device, e.g., digital camera or video camera or the like, the device must be connected to a connector usually on the back of the PC, which is quite cumbersome. Until recently, digital data communication has typically been represented by two-way communication between a PC and its peripherals. Therefore, aforementioned communication method did not cause any inconvenience. However, as the number of types of devices handling digital data increases and I/F improves, communication is performed not only between a PC and peripherals but also through a network which connects many digital devices, e.g., a digital video camera or digital recording medium driver apparatus or the like. This advancement has facilitated communication, and has enabled some devices to transmit an extremely large amount of data. However, using aforementioned communication method in such data transmission congests the network, and may influence other communication between devices in the network.
In view of this, means has been proposed to solve these problems related to the conventional digital I/F, and realize data communication not only between a PC and its peripherals but also among any digital devices through a general-purpose digital I/F uniformly incorporated in each device (e.g., High-Performance Serial Bus in compliance with IEEE 1394-1995). In such configuration, data communication is possible among devices such as a PC, printer, other peripherals, digital camera, digital video tape recorder (VTR) integrating a camera, or the like, through a network.
Main features of the IEEE 1394-compliant serial bus include: a relatively thin cable because of adoption of high-speed serial communication as will be described later; high flexibility; an extremely small connector compared to the SCSI cable; and high-speed transfer capability of transferring a large amount of data such as image data together with device control data.
In other words, performing communication using the IEEE 1394-compliant I/F provides an advantage in that, even in a case of connecting a mobile, portable, non-desktop-type device such as a digital camera or video camera or the like to a PC through a network, the aforementioned cumbersome operation is considerably reduced, and image data can be smoothly transferred to the PC.
As described above, the IEEE 1394-compliant I/F provides various convenient aspects for eliminating cumbersome operation of the conventional data communication system. Particularly, because of the advantage of high-speed transfer capability of transferring a large amount of data, e.g., image data, together with device control data, a new system can be constructed for enabling a PC to control an image sensing apparatus such as a video camera through a network.
In a system having such a construction, it has become an object to achieve stable operation of an electronic device such as a video camera, even when errors occur during data communication.
The present invention is made in consideration of the above situation, and has as its object to enable stable operation of an electronic device even if communication errors occur.
According to the present invention, the foregoing object is attained by providing an electronic device comprising: communication means for communicating with an external control apparatus; a control target to be controlled by the external control apparatus based on control data; first memory for temporarily storing the control data from the external control apparatus; second memory for storing the control data stored in the first memory; third memory for storing predetermined standard data of control data; error detection means for detecting a communication error occurred in communication with the external control apparatus; and control means for deleting the control data stored in the first memory when the communication error is detected, and controlling the control target based on the control data stored in the second memory or the predetermined standard data stored in the third memory.
According to the present invention, the foregoing object is also attained by providing an electronic device comprising: communication means for communicating with an external control apparatus; a control target to be controlled by the external control apparatus based on control data; first memory for temporarily storing the control data from the external control apparatus; second memory for storing the control data stored in the first memory; third memory for storing predetermined standard data of control data; a counter for counting a number of items of the control data transmitted by the external control apparatus; comparison means for comparing a counter value with a threshold value; error detection means for detecting a communication error occurred in communication with the external control apparatus; and control means for deleting the control data stored in the first memory in accordance with a comparison result of the comparison means at the time of detection, or transferring the control data stored in the first memory to the second memory when the communication error is detected, and controlling the control target based on the control data stored in the second memory or the predetermined standard data stored in the third memory.
Further, the foregoing object is also attained by providing an electronic device comprising: communication means for communicating with an external control apparatus; a control target to be controlled by the external control apparatus based on control data; first memory for temporarily storing the control data from the external control apparatus; second memory for storing the control data stored in the first memory; third memory for storing predetermined standard data of control data; determination means for determining reliability of the control data stored in the first memory; error detection means for detecting a communication error; and control means for deleting the control data stored in the first memory in accordance with a determination result of the determination means, or transferring the control data stored in the first memory to the second memory when the communication error is detected, and controlling the control target based on the control data stored in the second memory or the predetermined standard data stored in the third memory.
Further, the foregoing object is also attained by providing a control method of an electronic device having first memory which stores predetermined standard data of control data for a control target, the method comprising: a communication step of communicating with an external control apparatus; a first storage step of temporarily storing control data from the external control apparatus in second memory; an error determination step of determining whether or not an error has occurred in communication with the external control apparatus; a second storage step of storing the control data, stored in the second memory, in third memory, when determination is made in the error determination step that no communication error has occurred; and a control step of deleting the control data stored in the second memory when determination is made in the error determination step that a communication error has occurred, and controlling the control target based on the control data stored in the third memory or the predetermined standard data stored in the first memory.
Further, the foregoing object is also attained by providing a control method of an electronic device having first memory which stores predetermined standard data of control data for a control target, the method comprising: a communication step of communicating with an external control apparatus; a first storage step of temporarily storing control data from the external control apparatus in second memory; a counting step of counting a number of items of the control data transmitted by the external control apparatus; a comparison step of comparing a counter value with a threshold value; an error determination step of determining whether or not an error has occurred in communication with the external control apparatus; a second storage step of storing the control data, stored in the second memory, in third memory, when determination is made in the error determination step that no communication error has occurred; and a control step of deleting the control data stored in the second memory or transferring the control data stored in the second memory to the third memory in accordance with a comparison result of the comparison step when determination is made in the error determination step that a communication error has occurred, and controlling the control target based on the control data stored in the third memory or the predetermined standard data stored in the first memory.
Further, the foregoing object is also attained by providing a control method of an electronic device having first memory which stores predetermined standard data of control data for a control target, the method comprising: a communication step of communicating with an external control apparatus; a first storage step of temporarily storing control data from the external control apparatus in second memory; a reliability determination step of determining reliability of the control data stored in the second memory; an error determination step of determining whether or not an error has occurred in communication with the external control apparatus; a second storage step of storing the control data, stored in the second memory, in third memory, when determination is made in the error determination step that no communication error has occurred; and a control step of deleting the control data stored in the second memory or transferring the control data stored in the second memory to the third memory in accordance with a determination result of the reliability determination step when determination is made in the error determination step that a communication error has occurred, and controlling the control target based on the control data stored in the third memory or the predetermined standard data stored in the first memory.